package com.qire.manhua.model.vo;

import com.qire.manhua.model.entity.TaskEntity;
import com.qire.common.model.enumeration.RewardType;

public class TaskListDataVO {
    public TaskDataItemVO[] daily_task;    //: [每日任务],
    public TaskDataItemVO[] aims_task;     //: [目标任务]
    public class TaskDataItemVO {
        public int      task_id;                    //: 112,
        public String task_name;                  //任务名称                      例: "每日签到领金豆",
        public int      reward_type;                //奖励类型 1-金豆 2-会员         例: 2,
        public int      bean_num;                   //奖励数量                      例: 10,
        public int      state;                      //任务状态 0 完成待领取，1完成已领取， 2 未完成

        public TaskEntity toTaskEntity(){
            return new TaskEntity(task_id,task_name,bean_num, RewardType.build(reward_type),state);
        }
    }
}
